package cn.wolfcode.redis.web.controller;

import cn.wolfcode.redis.service.IArticlesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("articles")
public class ArticleController {

    @Autowired
    private IArticlesService articlesService;

    //接收请求
    @PostMapping("/incr")
    public Integer incr(Long id){

        return articlesService.incr(id);
    }
}
